package com.example.mvpdemo.mvp4;


import com.example.mvpdemo.mvp3.LoginModel3;
import com.example.mvpdemo.mvp3.base.BasePresenter3;
import com.example.mvpdemo.mvp4.base.BasePresenter4;
import com.example.mvpdemo.net.NetworkCallback;

public class LoginPresenter4 extends BasePresenter4 <ILoginView4>{
    private LoginModel4 loginModel4;

    public LoginPresenter4() {
        loginModel4 = new LoginModel4();
    }

    public void login(String username, String psd) {
        loginModel4.login(username, psd, new NetworkCallback() {
            @Override
            public void result(String result) {
                if (getView() != null)
                    getView().onLoginResult(result);
            }
        });
    }


}
